<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>

<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <title>科泰超市管理系统</title>

</head>

<body class="nav-md">


<center>
    <h2><button onclick="location.href='add'">添加</button></h2>
    <table border="1">
        <tr id="a">
            <th>主播姓名</th>
            <th>直播平台</th>
            <th>带货产品</th>
            <th>直播时间</th>
            <th>操作</th>
        </tr>
        <c:forEach items="${list}" var="item">
            <tr>
                <td>${item.streamer}</td>
                <td>${item.livePlatform}</td>
                <td>${item.product}</td>
                <td>
                    <fmt:formatDate value="${item.liveTime}" pattern="yyyy-MM-dd HH:mm:ss"/>
                </td>
                <td><button onclick="location.href='detail?id=${item.id}'"/>详情</td>
            </tr>
        </c:forEach>
    </table>
</center>
</body>
</html>
